#!/usr/bin/env python
try:
    import gtk, pygtk, os, os.path, pynotify
    pygtk.require('2.0')
except:
    print "Error: need python-notify, python-gtk2 and gtk"

def notify (title, data):
    if not pynotify.init("Timekpr notification"):
        sys.exit(1)

    n = pynotify.Notification(title, data)

    if not n.show():
        print "Failed to send notification"
        sys.exit(1)
